
  <div class="x_panel">
    <div class="x_content row">
      <div class="col-xs-12">
        <form class="form-horizontal form-label-left" action="{$actionUrl}" method="post" enctype="multipart/form-data">
          <div class="form-group">
            <label class="control-label col-md-2 col-sm-4 col-xs-12">广告标题：</label>
            <div class="checkbox col-md-10 col-sm-8 col-xs-12">
              <input class="form-control col-md-3 col-xs-12" required="required" type="text" name="form[adv_title]" value="{$adv.adv_title}">
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">广告图片：</label>
            <div class="col-md-10 col-sm-12 com-xs-12">
              <img style="width:100px;height:100px;" src="{$pic}"/>
              <input type="file" name="pic">
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">广告链接：</label>
            <div class="checkbox col-md-10 col-sm-8 col-xs-12">
              <input class="form-control col-md-3 col-xs-12" required="required" type="text" name="form[adv_link]" value="{$adv.adv_link}">
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">开始时间：</label>
            <div class="checkbox col-md-10 col-sm-8 col-xs-12">
              <input type="text"  name="form[start_time]" value="{$adv.start_time}" placeholder="开始时间" id="J_dh_start" class="form-control-new" >
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">结束时间：</label>
            <div class="checkbox col-md-10 col-sm-8 col-xs-12">
              <input type="text"  name="form[end_time]" value="{$adv.end_time}" placeholder="结束时间" id="J_dh_end" class="form-control-new" >
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">投放位置：</label>
            <div class="checkbox col-md-10 col-sm-8 col-xs-12">
              <select name="form[adv_position]" class="form-control-new">
                <option {if $adv.adv_position==0}selected="selected"{/if} value="0">首页</option>
              </select>
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">排序：</label>
            <div class="checkbox col-md-10 col-sm-8 col-xs-12">
              <input class="form-control-new col-md-3 col-xs-12" placeholder="数字越小，排序越靠前" required="required" type="text" name="form[adv_sort]" value="{$adv.adv_sort}">
            </div>

            <label class="control-label col-md-2 col-sm-4 col-xs-12">状态：</label>
            <div class="col-md-10 col-sm-9 col-xs-12">
              <input  type="radio" {if $adv.adv_status==1}checked="checked"{/if} name="form[adv_status]" value="1" />启用
              <input  type="radio" {if $adv.adv_status==0}checked="checked"{/if} name="form[adv_status]" value="0" />停用
            </div>

          </div>
          <div class="col-md-3 col-sm-12 col-xs-12 col-md-offset-4 col-sm-offset-4">
            <input name="adv_id" type="hidden" value="{$adv.adv_id}">
            <button class="btn btn-primary" type="submit">更新</button>
          </div>
        </form>
      </div>
    </div>
  </div>

  <script type="text/javascript" src="{$theme}/libs/js/datepicker/bootstrap-datetimepicker.min.js"></script>
  <script>
      var startDate = $('#J_dh_start').datetimepicker({
          format: "yyyy-MM-dd hh:ii:ss",
          autoclose: true,
          todayBtn: true
      })

      var endDate = $('#J_dh_end').datetimepicker({
          format: "yyyy-MM-dd hh:ii:ss",
          autoclose: true,
          todayBtn: true
      })
  </script>
